package com.amat0urheu.controller;


import com.amat0urheu.pojo.ReturnRes;
import com.amat0urheu.service.cloudService.CloudService;
import com.amat0urheu.util.DockerApiUtil;
import com.amat0urheu.util.JCloudsNova;
import com.amat0urheu.util.TestUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.web.bind.annotation.*;

@RestController
@RequestMapping("/api")
public class testController {
    @Autowired
    CloudService cloudService;

    //    @PreAuthorize("hasAuthority('ROLE_user')")

    @GetMapping("/test")
    ReturnRes getAllOpenstack() {

        try {
            DockerApiUtil.info();
        }catch (Exception e){
            e.printStackTrace();
        }
        return null;
    }
}